<?php

$siteId = "";

if(@$_GET["siteid"]){
	
	$siteId = $_GET["siteid"];
}

$EnglishID = getEnglishID($siteId);

$obChosenTag = $XML1 -> getTag($siteId);

if($obChosenTag -> getData("x_name") == "title"){
	
	addContent($obChosenTag -> GetAttributeByKey("value"));
}
else{
	
	$sql = "SELECT x_content FROM '".$PROJECT_DB_TABLES["tags"]."' WHERE x_id = '".$EnglishID."'";
	
	$tagContentResult = getRecord($sql);
	
	$cdataContent = $obChosenTag->getData("x_content");
	
	$cdataContent = str_replace("<![CDATA[","",$cdataContent);
	
	$cdataContent = str_replace("]]>","",$cdataContent);
	
	$arrResult = getTagByID($EnglishID);

	addContent($arrResult[0]["x_content"]);
	
	addContent("@break;");
	
	addContent($cdataContent);
	
	addContent("@break;");
	
	addContent($obChosenTag->getData("x_comment"));
}

?>